\(\int \frac {(a+b \log (c x^n))^3}{x^4} \, dx\) [64]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [B] (verification not implemented)
   Sympy [B] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [B] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 16, antiderivative size = 77 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^4} \, dx=-\frac {2 b^3 n^3}{27 x^3}-\frac {2 b^2 n^2 \left (a+b \log \left (c x^n\right )\right )}{9 x^3}-\frac {b n \left (a+b \log \left (c x^n\right )\right )^2}{3 x^3}-\frac {\left (a+b \log \left (c x^n\right )\right )^3}{3 x^3} \]

[Out]

-2/27*b^3*n^3/x^3-2/9*b^2*n^2*(a+b*ln(c*x^n))/x^3-1/3*b*n*(a+b*ln(c*x^n))^2/x^3-1/3*(a+b*ln(c*x^n))^3/x^3

Rubi [A] (verified)

Time = 0.04 (sec) , antiderivative size = 77, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.125, Rules used = {2342, 2341} \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^4} \, dx=-\frac {2 b^2 n^2 \left (a+b \log \left (c x^n\right )\right )}{9 x^3}-\frac {b n \left (a+b \log \left (c x^n\right )\right )^2}{3 x^3}-\frac {\left (a+b \log \left (c x^n\right )\right )^3}{3 x^3}-\frac {2 b^3 n^3}{27 x^3} \]

[In]

Int[(a + b*Log[c*x^n])^3/x^4,x]

[Out]

(-2*b^3*n^3)/(27*x^3) - (2*b^2*n^2*(a + b*Log[c*x^n]))/(9*x^3) - (b*n*(a + b*Log[c*x^n])^2)/(3*x^3) - (a + b*L
og[c*x^n])^3/(3*x^3)

Rule 2341

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[(d*x)^(m + 1)*((a + b*Log[c*x^
n])/(d*(m + 1))), x] - Simp[b*n*((d*x)^(m + 1)/(d*(m + 1)^2)), x] /; FreeQ[{a, b, c, d, m, n}, x] && NeQ[m, -1
]

Rule 2342

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[(d*x)^(m + 1)*((a + b*Lo
g[c*x^n])^p/(d*(m + 1))), x] - Dist[b*n*(p/(m + 1)), Int[(d*x)^m*(a + b*Log[c*x^n])^(p - 1), x], x] /; FreeQ[{
a, b, c, d, m, n}, x] && NeQ[m, -1] && GtQ[p, 0]

Rubi steps \begin{align*} \text {integral}& = -\frac {\left (a+b \log \left (c x^n\right )\right )^3}{3 x^3}+(b n) \int \frac {\left (a+b \log \left (c x^n\right )\right )^2}{x^4} \, dx \\ & = -\frac {b n \left (a+b \log \left (c x^n\right )\right )^2}{3 x^3}-\frac {\left (a+b \log \left (c x^n\right )\right )^3}{3 x^3}+\frac {1}{3} \left (2 b^2 n^2\right ) \int \frac {a+b \log \left (c x^n\right )}{x^4} \, dx \\ & = -\frac {2 b^3 n^3}{27 x^3}-\frac {2 b^2 n^2 \left (a+b \log \left (c x^n\right )\right )}{9 x^3}-\frac {b n \left (a+b \log \left (c x^n\right )\right )^2}{3 x^3}-\frac {\left (a+b \log \left (c x^n\right )\right )^3}{3 x^3} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.02 (sec) , antiderivative size = 60, normalized size of antiderivative = 0.78 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^4} \, dx=-\frac {9 \left (a+b \log \left (c x^n\right )\right )^3+b n \left (9 \left (a+b \log \left (c x^n\right )\right )^2+2 b n \left (3 a+b n+3 b \log \left (c x^n\right )\right )\right )}{27 x^3} \]

[In]

Integrate[(a + b*Log[c*x^n])^3/x^4,x]

[Out]

-1/27*(9*(a + b*Log[c*x^n])^3 + b*n*(9*(a + b*Log[c*x^n])^2 + 2*b*n*(3*a + b*n + 3*b*Log[c*x^n])))/x^3

Maple [A] (verified)

Time = 0.27 (sec) , antiderivative size = 116, normalized size of antiderivative = 1.51

method result size
parallelrisch \(-\frac {9 b^{3} \ln \left (c \,x^{n}\right )^{3}+9 \ln \left (c \,x^{n}\right )^{2} b^{3} n +6 \ln \left (c \,x^{n}\right ) b^{3} n^{2}+2 b^{3} n^{3}+27 a \,b^{2} \ln \left (c \,x^{n}\right )^{2}+18 \ln \left (c \,x^{n}\right ) a \,b^{2} n +6 a \,b^{2} n^{2}+27 a^{2} b \ln \left (c \,x^{n}\right )+9 a^{2} b n +9 a^{3}}{27 x^{3}}\) \(116\)
risch \(\text {Expression too large to display}\) \(2674\)

[In]

int((a+b*ln(c*x^n))^3/x^4,x,method=_RETURNVERBOSE)

[Out]

-1/27/x^3*(9*b^3*ln(c*x^n)^3+9*ln(c*x^n)^2*b^3*n+6*ln(c*x^n)*b^3*n^2+2*b^3*n^3+27*a*b^2*ln(c*x^n)^2+18*ln(c*x^
n)*a*b^2*n+6*a*b^2*n^2+27*a^2*b*ln(c*x^n)+9*a^2*b*n+9*a^3)

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 191 vs. \(2 (69) = 138\).

Time = 0.32 (sec) , antiderivative size = 191, normalized size of antiderivative = 2.48 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^4} \, dx=-\frac {9 \, b^{3} n^{3} \log \left (x\right )^{3} + 2 \, b^{3} n^{3} + 9 \, b^{3} \log \left (c\right )^{3} + 6 \, a b^{2} n^{2} + 9 \, a^{2} b n + 9 \, a^{3} + 9 \, {\left (b^{3} n + 3 \, a b^{2}\right )} \log \left (c\right )^{2} + 9 \, {\left (b^{3} n^{3} + 3 \, b^{3} n^{2} \log \left (c\right ) + 3 \, a b^{2} n^{2}\right )} \log \left (x\right )^{2} + 3 \, {\left (2 \, b^{3} n^{2} + 6 \, a b^{2} n + 9 \, a^{2} b\right )} \log \left (c\right ) + 3 \, {\left (2 \, b^{3} n^{3} + 9 \, b^{3} n \log \left (c\right )^{2} + 6 \, a b^{2} n^{2} + 9 \, a^{2} b n + 6 \, {\left (b^{3} n^{2} + 3 \, a b^{2} n\right )} \log \left (c\right )\right )} \log \left (x\right )}{27 \, x^{3}} \]

[In]

integrate((a+b*log(c*x^n))^3/x^4,x, algorithm="fricas")

[Out]

-1/27*(9*b^3*n^3*log(x)^3 + 2*b^3*n^3 + 9*b^3*log(c)^3 + 6*a*b^2*n^2 + 9*a^2*b*n + 9*a^3 + 9*(b^3*n + 3*a*b^2)
*log(c)^2 + 9*(b^3*n^3 + 3*b^3*n^2*log(c) + 3*a*b^2*n^2)*log(x)^2 + 3*(2*b^3*n^2 + 6*a*b^2*n + 9*a^2*b)*log(c)
 + 3*(2*b^3*n^3 + 9*b^3*n*log(c)^2 + 6*a*b^2*n^2 + 9*a^2*b*n + 6*(b^3*n^2 + 3*a*b^2*n)*log(c))*log(x))/x^3

Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 158 vs. \(2 (75) = 150\).

Time = 0.31 (sec) , antiderivative size = 158, normalized size of antiderivative = 2.05 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^4} \, dx=- \frac {a^{3}}{3 x^{3}} - \frac {a^{2} b n}{3 x^{3}} - \frac {a^{2} b \log {\left (c x^{n} \right )}}{x^{3}} - \frac {2 a b^{2} n^{2}}{9 x^{3}} - \frac {2 a b^{2} n \log {\left (c x^{n} \right )}}{3 x^{3}} - \frac {a b^{2} \log {\left (c x^{n} \right )}^{2}}{x^{3}} - \frac {2 b^{3} n^{3}}{27 x^{3}} - \frac {2 b^{3} n^{2} \log {\left (c x^{n} \right )}}{9 x^{3}} - \frac {b^{3} n \log {\left (c x^{n} \right )}^{2}}{3 x^{3}} - \frac {b^{3} \log {\left (c x^{n} \right )}^{3}}{3 x^{3}} \]

[In]

integrate((a+b*ln(c*x**n))**3/x**4,x)

[Out]

-a**3/(3*x**3) - a**2*b*n/(3*x**3) - a**2*b*log(c*x**n)/x**3 - 2*a*b**2*n**2/(9*x**3) - 2*a*b**2*n*log(c*x**n)
/(3*x**3) - a*b**2*log(c*x**n)**2/x**3 - 2*b**3*n**3/(27*x**3) - 2*b**3*n**2*log(c*x**n)/(9*x**3) - b**3*n*log
(c*x**n)**2/(3*x**3) - b**3*log(c*x**n)**3/(3*x**3)

Maxima [A] (verification not implemented)

none

Time = 0.19 (sec) , antiderivative size = 136, normalized size of antiderivative = 1.77 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^4} \, dx=-\frac {1}{27} \, {\left (2 \, n {\left (\frac {n^{2}}{x^{3}} + \frac {3 \, n \log \left (c x^{n}\right )}{x^{3}}\right )} + \frac {9 \, n \log \left (c x^{n}\right )^{2}}{x^{3}}\right )} b^{3} - \frac {2}{9} \, a b^{2} {\left (\frac {n^{2}}{x^{3}} + \frac {3 \, n \log \left (c x^{n}\right )}{x^{3}}\right )} - \frac {b^{3} \log \left (c x^{n}\right )^{3}}{3 \, x^{3}} - \frac {a b^{2} \log \left (c x^{n}\right )^{2}}{x^{3}} - \frac {a^{2} b n}{3 \, x^{3}} - \frac {a^{2} b \log \left (c x^{n}\right )}{x^{3}} - \frac {a^{3}}{3 \, x^{3}} \]

[In]

integrate((a+b*log(c*x^n))^3/x^4,x, algorithm="maxima")

[Out]

-1/27*(2*n*(n^2/x^3 + 3*n*log(c*x^n)/x^3) + 9*n*log(c*x^n)^2/x^3)*b^3 - 2/9*a*b^2*(n^2/x^3 + 3*n*log(c*x^n)/x^
3) - 1/3*b^3*log(c*x^n)^3/x^3 - a*b^2*log(c*x^n)^2/x^3 - 1/3*a^2*b*n/x^3 - a^2*b*log(c*x^n)/x^3 - 1/3*a^3/x^3

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 204 vs. \(2 (69) = 138\).

Time = 0.34 (sec) , antiderivative size = 204, normalized size of antiderivative = 2.65 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^4} \, dx=-\frac {b^{3} n^{3} \log \left (x\right )^{3}}{3 \, x^{3}} - \frac {{\left (b^{3} n^{3} + 3 \, b^{3} n^{2} \log \left (c\right ) + 3 \, a b^{2} n^{2}\right )} \log \left (x\right )^{2}}{3 \, x^{3}} - \frac {{\left (2 \, b^{3} n^{3} + 6 \, b^{3} n^{2} \log \left (c\right ) + 9 \, b^{3} n \log \left (c\right )^{2} + 6 \, a b^{2} n^{2} + 18 \, a b^{2} n \log \left (c\right ) + 9 \, a^{2} b n\right )} \log \left (x\right )}{9 \, x^{3}} - \frac {2 \, b^{3} n^{3} + 6 \, b^{3} n^{2} \log \left (c\right ) + 9 \, b^{3} n \log \left (c\right )^{2} + 9 \, b^{3} \log \left (c\right )^{3} + 6 \, a b^{2} n^{2} + 18 \, a b^{2} n \log \left (c\right ) + 27 \, a b^{2} \log \left (c\right )^{2} + 9 \, a^{2} b n + 27 \, a^{2} b \log \left (c\right ) + 9 \, a^{3}}{27 \, x^{3}} \]

[In]

integrate((a+b*log(c*x^n))^3/x^4,x, algorithm="giac")

[Out]

-1/3*b^3*n^3*log(x)^3/x^3 - 1/3*(b^3*n^3 + 3*b^3*n^2*log(c) + 3*a*b^2*n^2)*log(x)^2/x^3 - 1/9*(2*b^3*n^3 + 6*b
^3*n^2*log(c) + 9*b^3*n*log(c)^2 + 6*a*b^2*n^2 + 18*a*b^2*n*log(c) + 9*a^2*b*n)*log(x)/x^3 - 1/27*(2*b^3*n^3 +
 6*b^3*n^2*log(c) + 9*b^3*n*log(c)^2 + 9*b^3*log(c)^3 + 6*a*b^2*n^2 + 18*a*b^2*n*log(c) + 27*a*b^2*log(c)^2 +
9*a^2*b*n + 27*a^2*b*log(c) + 9*a^3)/x^3

Mupad [B] (verification not implemented)

Time = 0.41 (sec) , antiderivative size = 110, normalized size of antiderivative = 1.43 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^4} \, dx=-\frac {\frac {a^3}{3}+\frac {a^2\,b\,n}{3}+\frac {2\,a\,b^2\,n^2}{9}+\frac {2\,b^3\,n^3}{27}}{x^3}-\frac {\ln \left (c\,x^n\right )\,\left (3\,a^2\,b+2\,a\,b^2\,n+\frac {2\,b^3\,n^2}{3}\right )}{3\,x^3}-\frac {{\ln \left (c\,x^n\right )}^2\,\left (\frac {n\,b^3}{3}+a\,b^2\right )}{x^3}-\frac {b^3\,{\ln \left (c\,x^n\right )}^3}{3\,x^3} \]

[In]

int((a + b*log(c*x^n))^3/x^4,x)

[Out]

- (a^3/3 + (2*b^3*n^3)/27 + (2*a*b^2*n^2)/9 + (a^2*b*n)/3)/x^3 - (log(c*x^n)*(3*a^2*b + (2*b^3*n^2)/3 + 2*a*b^
2*n))/(3*x^3) - (log(c*x^n)^2*(a*b^2 + (b^3*n)/3))/x^3 - (b^3*log(c*x^n)^3)/(3*x^3)